package com.zlc.common.core.process.service.impl;

import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.zlc.common.common.service.BaseServiceImpl;
import com.zlc.common.core.process.model.entity.StoneProcess;
import com.zlc.common.core.process.model.entity.StoneProcessInstance;
import com.zlc.common.core.process.mapper.StoneProcessInstanceMapper;
import com.zlc.common.core.process.model.vo.StoneProcessInstanceVo;
import com.zlc.common.core.process.service.StoneProcessInstanceService;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

/**
 * @author  zl
 * @date 2023-10-17 
 */
@Service
@Transactional(rollbackFor = Exception.class)
public class StoneProcessInstanceServiceImpl extends BaseServiceImpl<StoneProcessInstanceMapper, StoneProcessInstance, StoneProcessInstanceVo> implements StoneProcessInstanceService{

    @Override
    public StoneProcessInstanceVo getByProcessInstanceId(String processInstanceId) {
        LambdaQueryWrapper<StoneProcessInstance> wrapper = wrapper().eq(StoneProcessInstance::getProcessInstanceId, processInstanceId);
        return queryOne(wrapper);
    }
}
